package com.example.demo;

import java.io.File;
import java.io.FileFilter;

public class FileDemo {

    public static void main(String[] args) {
        //java7值(类，对象)传递
        File[] files01 = new File(".").listFiles(new FileFilter() {
            @Override
            public boolean accept(File pathname) {
                return pathname.isHidden();
            }
        });
        //java8方法传递
        File[] files02 = new File(".").listFiles(File::isHidden);

    }
}
